package com.xtx.properties;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

@Component
/**
 * 该注解用于绑定配置文件中以"xtx.jwt"为前缀的属性到此类的字段上
 * 实现配置与Java对象的映射，简化配置读取操作
 */
@ConfigurationProperties(prefix = "xtx.jwt")
@Data
public class JwtProperties {
    /*
        用于用户生成jwt令牌的相关配置
     */
    private String userSecretKey;
    private long userTtl;
    private String userTokenName;
}
